﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using Telerik.WinControls;

using LIM.forms.uc_TaiSan_NhapMoiTaiSan;

namespace LIM.forms
{
    public partial class radForm_TaiSan_NhapMoiTaiSan : Telerik.WinControls.UI.RadForm
    {
        public radForm_TaiSan_NhapMoiTaiSan()
        {
            InitializeComponent();
            //this.radLabel_NoteForDelete.AutoSize = false;
            radGridView2.DataSource = GetTable();
        }

        private void radButton_TaoMoiLienHe_Click(object sender, EventArgs e)
        {
            radForm_CRM_LienHe_ChiTiet form = new radForm_CRM_LienHe_ChiTiet();            
            //form.MdiParent = this.MdiParent;
            form.ShowDialog();
        }

        private void radForm_TaiSan_NhapMoiTaiSan_Load(object sender, EventArgs e)
        {
            uc_TaiSan_NhapMoiTaiSan_FileDinhKem uc_TaiSan_NhapMoiTaiSan_FileDinhKem = new uc_TaiSan_NhapMoiTaiSan_FileDinhKem();
            uc_TaiSan_NhapMoiTaiSan_FileDinhKem.Dock = DockStyle.Fill;
            this.radPanel_FileDinhKem.Controls.Add(uc_TaiSan_NhapMoiTaiSan_FileDinhKem);
        }
        static DataTable GetTable()
        {
            //
            // Here we create a DataTable with four columns.
            //
            DataTable table = new DataTable();
            table.Columns.Add("STT", typeof(int));
            table.Columns.Add("NgayDuKien", typeof(string));
            table.Columns.Add("NgayThucHien", typeof(string));
            table.Columns.Add("MoTaCongViec", typeof(string));
            table.Columns.Add("NhanVienThucHien", typeof(string));

            table.Rows.Add(1,DateTime.Now.AddMonths(-2), DateTime.Now.AddMonths(10), "Kiểm tra máy móc còn ko","Nguyễn Văn A");
            table.Rows.Add(2, DateTime.Now.AddMonths(-3), DateTime.Now.AddMonths(17), "Kiểm tra hao mòn tài sản","Nguyễn Văn A");
            table.Rows.Add(3,  DateTime.Now.AddMonths(-2), DateTime.Now.AddMonths(10), "Kiểm tra SLL tài sản", "Nguyễn Văn B");
            return table;
        }

    }
}
